package com.ruoyi.whole.mapper;

import com.baomidou.mybatisplus.core.mapper.BaseMapper;
import com.ruoyi.whole.domain.DmsDealerVehicleInfo;
import com.ruoyi.whole.domain.DmsDealerWholePurchase;
import com.ruoyi.whole.domain.DmsDealerWholePurchaseDetail;
import com.ruoyi.whole.domain.vo.DmsDealerWholePurchaseVo;

import java.util.List;

/**
 * 车辆采购
Mapper接口
 * 
 * @author liuchuanfa
 * @date 2024-03-04
 */
public interface DmsDealerWholePurchaseMapper extends BaseMapper<DmsDealerWholePurchase>
{
    /**
     * 查询车辆采购
     *
     * @param id 车辆采购主键
     * @return 车辆采购
     */
    public DmsDealerWholePurchase selectDmsDealerWholePurchaseById(Long id);

    /**
     * 查询车辆采购列表
     * 
     * @param dmsDealerWholePurchase 车辆采购
     * @return 车辆采购集合
     */
    public List<DmsDealerWholePurchase> selectDmsDealerWholePurchaseList(DmsDealerWholePurchase dmsDealerWholePurchase);

    /**
     * 新增车辆采购
     * 
     * @param dmsDealerWholePurchase 车辆采购
     * @return 结果
     */
    public int insertDmsDealerWholePurchase(DmsDealerWholePurchase dmsDealerWholePurchase);

    /**
     * 修改车辆采购
     * 
     * @param dmsDealerWholePurchase 车辆采购
     * @return 结果
     */
    public int updateDmsDealerWholePurchase(DmsDealerWholePurchase dmsDealerWholePurchase);

    /**
     * 删除车辆采购
     * 
     * @param id 车辆采购主键
     * @return 结果
     */
    public int deleteDmsDealerWholePurchaseById(Long id);

    /**
     * 批量删除车辆采购

     * 
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteDmsDealerWholePurchaseByIds(Long[] ids);

    /**
     * 批量删除车辆采购详细

     * 
     * @param ids 需要删除的数据主键集合
     * @return 结果
     */
    public int deleteDmsDealerWholePurchaseDetailByPurchaseIds(Long[] ids);
    
    /**
     * 批量新增车辆采购详细

     * 
     * @param dmsDealerWholePurchaseDetailList 车辆采购详细列表
     * @return 结果
     */
    public int batchDmsDealerWholePurchaseDetail(List<DmsDealerWholePurchaseDetail> dmsDealerWholePurchaseDetailList);
    

    /**
     * 通过车辆采购主键删除车辆采购详细信息
     * 
     * @param id 车辆采购ID
     * @return 结果
     */
    public int deleteDmsDealerWholePurchaseDetailByPurchaseId(Long id);

    /**
     * 根据采购订单id，查询vin集合的详细信息
     * @param id
     * @return {@link DmsDealerVehicleInfo }
     * @author liuchuanfa
     * @since 2024/03/05
     */
    DmsDealerWholePurchaseVo selectDmsDealerVehicleInfoByPurchaseId(Long id);
}
